package com.pricl.frame.core;


/**
 * <p>
 * 异常类
 * </p>
 * 
 * @author cheng(iknoweth@yahoo.com)
 * @date 2016-5-4 下午10:18:15
 */
public class E extends RuntimeException {

	private static final long serialVersionUID = 1L;

	/** 异常代码 **/
	public int code;

	/** 异常数据 **/
	public Object data;

	public E(int code) {
		super();
		this.code = code;
	}

	public E(String message) {
		super(message);
		this.code = -1;
	}

	public E(Throwable cause) {
		super(cause);
		this.code = -1;
	}

	public E(int code, String message) {
		super(message);
		this.code = code;
	}

	public E(int code, Throwable cause) {
		super(cause);
		this.code = code;
	}

	public E(int code, String message, Throwable cause) {
		super(message, cause);
		this.code = code;
	}

	public E(Throwable cause, Object data) {
		super(cause);
		this.code = -1;
		this.data = data;
	}

	public E(int code, String message, Object data) {
		super(message);
		this.code = code;
		this.data = data;
	}
}
